<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="/context/mytags.jsp"%>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<t:base type="jquery,easyui,tools,DatePicker"></t:base>
<div id="ncFile" class="easyui-layout" fit="true">
	<div region="center" style="padding: 0px; border: 0px">
		<t:datagrid  pagination="true" name="userList" title="人员"  actionUrl="postController.do?datagridUser" idField="id" checkbox="true"  showRefresh="false"  fit="true"  queryMode="group" onLoadSuccess="initCheck">
			<t:dgCol title="id" field="id" hidden="true" ></t:dgCol>
			<t:dgCol title="姓名" field="realName" width="38" query="true" ></t:dgCol>
			<t:dgCol title="部门" sortable="false" field="userOrgList.tsDepart.departname" width="62" query="false"></t:dgCol>
		</t:datagrid>
	</div>
</div>
<script type="text/javascript">
//获取选中的信息-通用方法 add by XQG
function getParentWin(parentWindow){
	 var rows = $('#userList').datagrid('getSelections');
     parentWindow.chooseUserValue(rows, "User");
 	 return rows;
}

function initCheck(data){
	var ids = "${ids}";
	var idArr = ids.split(",");
	for(var i=0;i<idArr.length;i++){
		if(idArr[i]!=""){
			$("#userList").datagrid("selectRecord",idArr[i]);
		}
	}
}

</script>